package com.yang.booking.controller;

import com.yang.booking.service.RegionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

@RestController
public class RegionController {

    @Autowired
    private RegionService regionService;

    @PostMapping("/provider/region/insertRegion")
    public Map<String, Object> insertRegion(@RequestParam(name = "name") String name
    ){
        return regionService.insertRegion(name);
    }
}
